package mywebapp.tools.jsf;

import mywebapp.impl.*;
import mywebapp.dao.*;
import mywebapp.webpage.*;

public class FACES_VALIDATOR_JSF
{
  protected static String nl;
  public static synchronized FACES_VALIDATOR_JSF create(String lineSeparator)
  {
    nl = lineSeparator;
    FACES_VALIDATOR_JSF result = new FACES_VALIDATOR_JSF();
    nl = null;
    return result;
  }

  public final String NL = nl == null ? (System.getProperties().getProperty("line.separator")) : nl;
  protected final String TEXT_1 = NL + NL + "<!-- Les Validateurs des Formulaires -->" + NL + "<validator>" + NL + "\t<display-name>";
  protected final String TEXT_2 = ".validator.TextValidator</display-name>" + NL + "\t<validator-id>";
  protected final String TEXT_3 = ".validator.TextValidator</validator-id>" + NL + "\t<validator-class>";
  protected final String TEXT_4 = ".validator.TextValidator</validator-class>" + NL + "</validator>" + NL + "<validator>" + NL + "\t<display-name>";
  protected final String TEXT_5 = ".validator.PassWordValidator</display-name>" + NL + "\t<validator-id>";
  protected final String TEXT_6 = ".validator.PassWordValidator</validator-id>" + NL + "\t<validator-class>";
  protected final String TEXT_7 = ".validator.PassWordValidator</validator-class>" + NL + "</validator>" + NL + "<validator>" + NL + "\t<display-name>";
  protected final String TEXT_8 = ".validator.IntValidator</display-name>" + NL + "\t<validator-id>";
  protected final String TEXT_9 = ".validator.IntValidator</validator-id>" + NL + "\t<validator-class>";
  protected final String TEXT_10 = ".validator.IntValidator</validator-class>" + NL + "</validator>" + NL + "<validator>" + NL + "\t<display-name>";
  protected final String TEXT_11 = ".validator.DateValidator</display-name>" + NL + "\t<validator-id>";
  protected final String TEXT_12 = ".validator.DateValidator</validator-id>" + NL + "\t<validator-class>";
  protected final String TEXT_13 = ".validator.DateValidator</validator-class>" + NL + "</validator>" + NL;
  protected final String TEXT_14 = NL;

  public String generate(Object argument)
  {
    final StringBuffer stringBuffer = new StringBuffer();
     String nameApp = (String) argument; 
    stringBuffer.append(TEXT_1);
    stringBuffer.append(nameApp);
    stringBuffer.append(TEXT_2);
    stringBuffer.append(nameApp);
    stringBuffer.append(TEXT_3);
    stringBuffer.append(nameApp);
    stringBuffer.append(TEXT_4);
    stringBuffer.append(nameApp);
    stringBuffer.append(TEXT_5);
    stringBuffer.append(nameApp);
    stringBuffer.append(TEXT_6);
    stringBuffer.append(nameApp);
    stringBuffer.append(TEXT_7);
    stringBuffer.append(nameApp);
    stringBuffer.append(TEXT_8);
    stringBuffer.append(nameApp);
    stringBuffer.append(TEXT_9);
    stringBuffer.append(nameApp);
    stringBuffer.append(TEXT_10);
    stringBuffer.append(nameApp);
    stringBuffer.append(TEXT_11);
    stringBuffer.append(nameApp);
    stringBuffer.append(TEXT_12);
    stringBuffer.append(nameApp);
    stringBuffer.append(TEXT_13);
    stringBuffer.append(TEXT_14);
    return stringBuffer.toString();
  }
}
